package org.example.pojo;


import lombok.Data;
import org.springframework.stereotype.Component;

import java.util.Objects;

@Component
public class UsersTb {
    private  Integer userId;
    private  String userName;
    private String userPassword;
    private String userSex;
    private String userXh;
    private String userPhone;
    private String userStatus;


    public UsersTb() {
    }

    public UsersTb(Integer userId, String userName, String userPassword, String userSex, String userXh, String userPhone, String userStatus) {
        this.userId = userId;
        this.userName = userName;
        this.userPassword = userPassword;
        this.userSex = userSex;
        this.userXh = userXh;
        this.userPhone = userPhone;
        this.userStatus = userStatus;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getUserPassword() {
        return userPassword;
    }

    public void setUserPassword(String userPassword) {
        this.userPassword = userPassword;
    }

    public String getUserSex() {
        return userSex;
    }

    public void setUserSex(String userSex) {
        this.userSex = userSex;
    }

    public String getUserXh() {
        return userXh;
    }

    public void setUserXh(String userXh) {
        this.userXh = userXh;
    }

    public String getUserPhone() {
        return userPhone;
    }

    public void setUserPhone(String userPhone) {
        this.userPhone = userPhone;
    }

    public String getUserStatus() {
        return userStatus;
    }

    public void setUserStatus(String userStatus) {
        this.userStatus = userStatus;
    }

    @Override
    public String toString() {
        return "UsersTb{" +
                "userId=" + userId +
                ", userName='" + userName + '\'' +
                ", userPassword='" + userPassword + '\'' +
                ", userSex='" + userSex + '\'' +
                ", userXh='" + userXh + '\'' +
                ", userPhone='" + userPhone + '\'' +
                ", userStatus='" + userStatus + '\'' +
                '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        UsersTb usersTb = (UsersTb) o;
        return Objects.equals(userId, usersTb.userId) && Objects.equals(userName, usersTb.userName) && Objects.equals(userPassword, usersTb.userPassword) && Objects.equals(userSex, usersTb.userSex) && Objects.equals(userXh, usersTb.userXh) && Objects.equals(userPhone, usersTb.userPhone) && Objects.equals(userStatus, usersTb.userStatus);
    }

    @Override
    public int hashCode() {
        return Objects.hash(userId, userName, userPassword, userSex, userXh, userPhone, userStatus);
    }
}
